
/**
 * 中间件的挂载方式
 */

const express = require('express');
const app = express();

app.get('/abc', (req, resp, next) => {
    console.log(1);
    // next();
    next('route');
}, (req, resp) => {
    console.log(2);
    resp.send('abc');
});

app.get('/abc', (req, resp) => {
    console.log(3);
    resp.send('hello');
});

app.listen(3000, () => {
    console.log('running...');
});
